#ifndef __FRAMEWORK_H__
#define __FRAMEWORK_H__
#include "yatengine.h"
#include "yatephone.h"
using namespace TelEngine;

#ifdef WIN32
#ifdef LIBFRAMEWORK_EXPORTS
#define FRAMEWORK_API __declspec(dllexport)
#else
#define FRAMEWORK_API __declspec(dllimport)
#endif
#else
#define FRAMEWORK_API
#endif

class FRAMEWORK_API SimpleThread {
public:
	SimpleThread();
	virtual ~SimpleThread();
	virtual void startup();
	virtual void run() = 0;
	virtual void cleanup() = 0;
	virtual void exit();
private:
	static void __cdecl __run(void*);
private:
	static int count;
};

class FRAMEWORK_API ParamAddress : public RefObject {
public:
	virtual void* getParam() = 0;
	virtual char* getDescription();
	virtual void* getObject(const String& name) const;
};

class FRAMEWORK_API XSIPRequestParam : public RefObject {
public:
	virtual void* getContentData() = 0;
	virtual int getContentLength() = 0;
	virtual void* getTransport() = 0;
	virtual void* getObject(const String& name) const;
};

class FRAMEWORK_API XSIPResponseParam : public RefObject {
public:
	virtual void* getContentData() = 0;
	virtual int getContentLength() = 0;
	virtual void* getObject(const String& name) const;
};

#endif